
<template>
  <a-modal title="公告信息" v-model="show" :maskClosable="false" :width="1300" placement="right" :closable="true"
    @cancel="onClose" :footer="null" :visiable="roleInfoVisiable">
    <a-form :form="form">
      <a-row>
        <a-col :md="12" :sm="24">
          <!-- initialValue:this.NotityInfoData.title这个是给表单赋公告首页传过来的值-->
          <a-form-item label='公告标题' :validateStatus="validateStatus" v-bind="formItemLayout">
            <a-input v-decorator="['title', {
              rules: [{ required: true, message: '用户登录账号不能为空' }], initialValue: this.notityInfoData.title
            }]" :disabled="true" />
          </a-form-item>
        </a-col>
        <a-col :md="12" :sm="24">
          <a-form-item label='公告开始期' v-bind="formItemLayout">
            <a-date-picker placeholder="请选择日期" name="reconFile1" style="width: 100%;" v-decorator="['beginTime', {
              rules: [{ required: true, message: '请输入公告开始日期' }], initialValue: this.notityInfoData.beginTime
            }]" format="YYYYMMDD" :disabled="true" />
          </a-form-item>
        </a-col>
      </a-row>
      <a-row>
        <a-col :md="12" :sm="24">
          <a-form-item label='公告有效期' v-bind="formItemLayout">
            <a-date-picker placeholder="请选择日期" style="width: 100%;" name="reconFileDate"
              v-decorator="['expireTime', { rules: [{ required: true, message: '请输入公告有效期' }], initialValue: this.notityInfoData.expireTime }]"
              format="YYYYMMDD" :disabled="true" />
          </a-form-item>
        </a-col>

        <a-col :md="12" :sm="24">
          <a-form-item label='公告内容' v-bind="formItemLayout">
            <a-textarea
              v-decorator="['message', { rules: [{ required: true, message: '请输入公告内容' }], initialValue: this.notityInfoData.message }]"
              :disabled="true" allow-clear />

          </a-form-item>
        </a-col>
      </a-row>
      <a-row>
        <a-col :md="12" :sm="24">
          <a-form-item label='商户号' v-bind="formItemLayout">
            <!-- {{ this.notityInfoData.circleList }} -->
            <a-textarea   v-decorator="['circleList' , {initialValue:this.notityInfoData.circleList} ]" :disabled="true" allow-clear />
          </a-form-item>
        </a-col>
        <a-col :md="12" :sm="24">
          <a-form-item label='商圈号' v-bind="formItemLayout">
            <a-textarea   v-decorator="['merchantList' , {initialValue:this.notityInfoData.merchantList} ]" :disabled="true" allow-clear />
            <!-- {{ notityInfoData.merchantList }} -->
          </a-form-item>
        </a-col>
      </a-row>
    </a-form>

  </a-modal>
</template>
<script>
const formItemLayout = {
  labelCol: { span: 5 },
  wrapperCol: { span: 14 }
}
export default {

  name: 'NotityInfo',
  props: {
    //弹框
    roleInfoVisiable: {
      default: false
    },
    notityInfoData: {
      require: true
    },
    roleInstId: '',
    roleCodeData: {
      type: Array,
      default: () => []

    }
  },
  data() {
    return {
      //给form表单赋默认值
      form: this.$form.createForm(this),
      key: +new Date(),
      loading: true,
      formItemLayout,
      checkedKeys: [],
      menuTreeData: [],
      roleLevel: '',
      validateStatus: '',
    }
  },
  computed: {
    show: {

      get: function () {
        return this.roleInfoVisiable
      },
      set: function () {
      }
    }
  },
  methods: {
    onClose() {
      this.$emit('close')
      // this.checkedKeys = []
    }
  }

}
</script>
